<?php

/**
 * @author PhatPham
 * @copyright 2013
 */
class DesignTemplatemodel extends CI_Model {
    var $design_template_id;    //dtid
    var $design_template_name;  //dtname
    var $template_link; //dtlink
    var $image_link;    //imglink
    var $is_deleted;
    var $created_by_user_id;    //userid
    var $created_on_date;
    var $last_modified_by_user_id;  //userid
    var $last_modified_on_date;
    
    function __construct()
    {
        // Call the Model constructor
        $this->load->database();
    }
    
    //Get design templates list
    function get_design_templates_list(){
        $query = $this->db->get_where('sur_design_template',array('is_deleted' => false));
        return $query;
    }
    
    //Get design template
    function get_design_template($dtid){
        $query = $this->db->get_where('sur_design_template', array('design_template_id' => $sid, 'is_deleted' => false));
        return $query->num_rows() > 0 ? $query->row() : null;
    }
}
?>